package com.xauto.pioneer.appuser.view;

import android.app.Dialog;
import android.content.Context;
import android.view.Gravity;
import android.view.View;
import android.widget.RelativeLayout;

import com.xauto.pioneer.appuser.R;

/***
 *  网点无车辆 提示页面
 * @author Lemon Wed 1 Mar 14:02
 */
public class ParkingSiteNoCarDialog extends Dialog {
    private Context mContext;
    /** 网点编号*/
    public String parking_site_no;
    public ParkingSiteNoCarDialog(Context context,String siteNo) {
        super(context, R.style.LoadingDialogTheme);
        mContext = context;
        this.parking_site_no = siteNo;
        initView();
    }

    protected void initView() {
        setContentView(R.layout.dialog_parking_site_no_car);
        getWindow().setGravity(Gravity.BOTTOM);
        getWindow().setLayout(RelativeLayout.LayoutParams.MATCH_PARENT, RelativeLayout.LayoutParams.WRAP_CONTENT);

        setCanceledOnTouchOutside(true);
        setCancelable(true);

        findViewById(R.id.tvRefreshParkingSite).setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                //刷新取车点
                dismiss();
                refreshParkingSites(parking_site_no);
            }
        });
    }
    /** 刷新取车点*/
    /**当前刷新的网点id*/
    private String currentRefreshSiteNo = "";
    public void refreshParkingSites(String parking_site_no) {
        currentRefreshSiteNo = parking_site_no;
//        loadAll(true,"");
    }
}
